package Employee;

import java.util.Scanner;

public class SalesEmployee implements Employee{
    int Month;
    double CommissionRate;
    double MonthlySales;
    @Override
    public double getSalary(int month) {
        Scanner scanner = new Scanner(System.in);
        System.out.println("请输入名字");
        String Name = scanner.nextLine();

        System.out.println("请输入生日月份");
        this.Month = scanner.nextInt();

        System.out.println("输入提成率");
        this.CommissionRate = scanner.nextDouble();

        System.out.println("输入该月销售额");
        this.MonthlySales = scanner.nextDouble();

        double money = CommissionRate*MonthlySales;

        return Month==month?money+100:money;
    }
}
